<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>上机4</title>
	</head>
	<body>
		<script type="text/javascript">
		function Person(name,chinese){
			this.name=name;
			this.chinese=chinese;
			
		}
		Person.prototype.a=function(){
			return this.name;
		}
		Person.prototype.b=function(){
			return this.chinese;
		}

		function Student(name,chinese,age){

			this.age=age;
			Person.call(this,name,chinese);
		}
		
		Student.prototype=new Person();
		Student.prototype.c=function(){
			return this.age;
		}
		var stu=new Student("叶良辰",0+"分",24+"岁");
		document.write("姓名："+stu.a()+"<br />");
		document.write("语文分数:"+stu.b()+"<br />");
		document.write("年纪:"+stu.c()+"<br />");
	</script>

	</body>
</html>
